﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using Cms.BLL.Article;
using Frame.Lib.Utilities;

namespace Cms.Admin.Picture
{
    /// <summary>
    /// $codebehindclassname$ 的摘要说明
    /// </summary>
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    public class Delete : IHttpHandler
    {

        public void ProcessRequest(HttpContext context)
        {
            string articleID = StrUtil.DecryptUrl(context.Request.QueryString["ArticleID"]);

            ArticleBO article = new ArticleBO();

            article.Delete(articleID);

            string url = context.Request.QueryString["FromUrl"] + ".aspx?MenuID=" + StrUtil.EncryptUrl(context.Request.QueryString["MenuID"]);
           
            context.Response.Redirect(url);
        }

        public bool IsReusable
        {
            get
            {
                return false;
            }
        }
    }
}
